package com.kittlen.springBootDemo.controller;


import com.kittlen.springBootDemo.entity.Result;
import com.kittlen.springBootDemo.service.IAuthorService;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author kittlen
 * @since 2020-12-08
 */
@RestController
@RequestMapping("/author")
public class AuthorController {

    @Resource
    IAuthorService iAuthorService;

    @RequestMapping("/selectAuthor")
    public Result selectAuthor(){
        Result result=new Result();
        result.setData(iAuthorService.list());
        return result;
    }
}
